﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Mobile;
using ListView = Mobile.WebControls.ListView;
using Common;
namespace CMS
{
    public partial class ctrLeftMenu : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {

            Control control = ControlHelper.GetControlById(mbCountryList, "lv");
            if (control is Mobile.WebControls.ListView)
            {
                Mobile.WebControls.ListView lv = control as ListView;
                lv.DataSource = Common.lstMenuManager.GetMenu();
                lv.DataBind();
                
            }
        }


        protected string GetUrl(string key)
        {
            return "Index.aspx?cid=" + key;
            
        }

        protected string GetImageUrl(string key)
        {
            return String.Format("/Images/Icon_{0}.png", key.ToLower());
        }
    }
}